package main

import (
	"fmt"

	"gitee.com/liuyongchina/go-library/config"
	"gitee.com/liuyongchina/go-library/libs/weapp"
)

func main() {
	config.TomlPath = "/Users/liuyong/go/src/go-library/toml/toml_dev/"
	code := "xxxx"
	grant, err := weapp.NewWeapp("test").CodeToSession(code)
	fmt.Println(grant)
	fmt.Println(err)

	// ylog.InitLog()
	// ylog.SugarLogger.Info("测试", "test", "value")
	// ylog.SugarLogger.Infow("测试", "test", "value")
	// ylog.SugarLogger.Infow("测试", "test", "value")
	// ylog.SugarLogger.Infow("测试", "test", "value")
	// defer ydefer.Clean()
	// fmt.Println("OVER")
	token, err := weapp.NewWeapp("test").TestAccessToken()
	fmt.Println(token)
	fmt.Println(err)
}
